﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/MasterPageAdmin.master" AutoEventWireup="true" CodeFile="Khachhang.aspx.cs" Inherits="Admin_Khachhang" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <table align="center" border="0" cellpadding="0" cellspacing="0" width="670px">
        <tr>
            <td style="height: 250px">
                <asp:MultiView ID="MultiView1" runat="server">
                    <asp:View ID="View1" runat="server">
                        <table align="center" border="0" cellpadding="5" cellspacing="5" style="width: 660px">
                         <tr>
                                <td>
                                    <table>
                                        <tr>
                                            <td style="width: 170px">
                                                Tìm Kiếm User:
                                            </td>
                                            <td align="center" style="width : 300px">
                                                <asp:TextBox ID="txttim" Width="250px" runat="server"></asp:TextBox>
                                            </td>
                                            <td style="width: 200px">
                                                <asp:Button ID="btntmkiem" runat="server" BackColor="#A52B2B" ForeColor="White" Text="Tìm Kiếm" Style="height: 26px" OnClick="btntmkiem_Click" />
                                                <asp:Button ID="btntrove" BackColor="#A52B2B" ForeColor="White" runat="server" onclick="btntrove_Click" 
                                                    Text="Trở Về" />
                                            </td>
                                        </tr>
                                        <tr>
                                            <td align="center" colspan="3">
                                                <asp:Label ID="Label1" runat="server" Text=""></asp:Label>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td align="center" style="height: 117px">
                                    <br />
                                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CellPadding="4"
                                        ForeColor="Black" GridLines="Both" 
                                        OnRowDeleting="GridView1_RowDeleting" OnSelectedIndexChanged="GridView1_SelectedIndexChanged"
                                        onpageindexchanging="GridView1_PageIndexChanging"

                                        AllowPaging="True" BackColor="White" BorderColor="#CCCCCC" 
                                        BorderStyle="Solid" BorderWidth="1px" Width="934px">
                                        <Columns>
                                            <asp:CommandField ShowSelectButton="True" ButtonType="Button" 
                                                HeaderText="Chọn KH" SelectText="Chọn" />
                                            <asp:CommandField ShowDeleteButton="True" ButtonType="Button" DeleteText="Xóa" 
                                                HeaderText="Xóa KH" />
                                            <asp:BoundField DataField="Email" HeaderText="Email" />
                                            <asp:BoundField DataField="Quyen" HeaderText="Quyền" />
                                            <asp:BoundField DataField="TenUsers" HeaderText="Họ Tên" />
                                            <asp:BoundField DataField="DiaChi" HeaderText="Địa Chỉ" />
                                            <asp:BoundField DataField="SDT" HeaderText="Số ĐT" />
                                            <asp:BoundField DataField="TenDN" HeaderText="Tên Đăng Nhập" />
                                            
                                        </Columns>
                                        <EmptyDataTemplate>
                                             Khách Hàng Không Tồn Tại !
                                        </EmptyDataTemplate>
                                        <FooterStyle BackColor="#CCCC99" ForeColor="Black" />
                                        <HeaderStyle BackColor="#333333" Font-Bold="True" ForeColor="White" />
                                        <PagerStyle BackColor="White" ForeColor="Black" HorizontalAlign="Right" />
                                        <SelectedRowStyle BackColor="#CC3333" Font-Bold="True" ForeColor="White" />
                                        <SortedAscendingCellStyle BackColor="#F7F7F7" />
                                        <SortedAscendingHeaderStyle BackColor="#4B4B4B" />
                                        <SortedDescendingCellStyle BackColor="#E5E5E5" />
                                        <SortedDescendingHeaderStyle BackColor="#242121" />
                                    </asp:GridView>
                                </td>
                            </tr>
                           
                        </table>
                    </asp:View>
                    <asp:View ID="VIew2" runat="server">
                        <table width="640px" cellpadding="5" cellspacing="5">
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Tên Đăng Nhập:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:Label ID="lbid" runat="server" Text="Label" Enabled="False"></asp:Label>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Họ Tên:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txthoten" Width="200px" runat="server" Enabled="False"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Địa Chỉ:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtdiachi" Width="200px" runat="server" Enabled="False"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Số ĐT:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtsdt" Width="200px" runat="server" Enabled="False"></asp:TextBox>
                                    <asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="txtsdt"
                                        ErrorMessage="*" MaximumValue="9999999999999" MinimumValue="1" Type="Double"
                                        ValidationGroup="khachhang"></asp:RangeValidator>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Email:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtemail" Width="200px" MaxLength="9" runat="server" 
                                        Enabled="False"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    Quyền:</td>
                                <td style="width: 450px" align="left">
                                    <asp:DropDownList ID="DropDownList1" runat="server">
                                        <asp:ListItem>1</asp:ListItem>
                                        <asp:ListItem>0</asp:ListItem>
                                    </asp:DropDownList>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 170px; height: 15px; font-weight: bold; font-size: 15px" align="right">
                                    &nbsp;</td>
                                <td style="width: 450px" align="left">
                                    <asp:Button ID="btnupdate" runat="server" BackColor="#A52B2B" ForeColor="White" OnClick="btnupdate_Click" 
                                        Text="Update" ValidationGroup="khachhang" Width="60px" />
                                    <asp:Button ID="btnback" runat="server"  BackColor="#A52B2B" ForeColor="White" OnClick="btnback_Click" Text="Trở Về" 
                                        Width="60px" />
                                </td>
                            </tr>
                        </table>
                    </asp:View>
                </asp:MultiView>
            </td>
        </tr>
    </table>
</asp:Content>

